﻿<Window
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:local="clr-namespace:UMLTouch_UI_Controls"
	xmlns:Microsoft_Windows_Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	x:Class="UMLTouch_UI_Controls.Start"
	x:Name="Window"
	Title="Start"
	Width="688" Height="490" Foreground="{x:Null}" mc:Ignorable="d" WindowStyle="ThreeDBorderWindow">

	<Window.Resources>
		<ResourceDictionary>
			<ResourceDictionary.MergedDictionaries>
				<ResourceDictionary Source="Simple Styles.xaml"/>
			</ResourceDictionary.MergedDictionaries>
			<Style x:Key="ButtonFocusVisual">
				<Setter Property="Control.Template">
					<Setter.Value>
						<ControlTemplate>
							<Rectangle Stroke="Black" StrokeDashArray="1 2" StrokeThickness="1" Margin="2" SnapsToDevicePixels="true"/>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>
			<LinearGradientBrush x:Key="ButtonNormalBackground" EndPoint="0,1" StartPoint="0,0">
				<GradientStop Color="#F3F3F3" Offset="0"/>
				<GradientStop Color="#EBEBEB" Offset="0.5"/>
				<GradientStop Color="#DDDDDD" Offset="0.5"/>
				<GradientStop Color="#CDCDCD" Offset="1"/>
			</LinearGradientBrush>
			<SolidColorBrush x:Key="ButtonNormalBorder" Color="#FF707070"/>
			<Storyboard x:Key="Storyboard1"/>
			<ControlTemplate x:Key="ButtonControlTemplate1" TargetType="{x:Type Button}">
				<Grid Height="21.96">
					<Ellipse Fill="{TemplateBinding Background}" d:LayoutOverrides="Height"/>
				</Grid>
			</ControlTemplate>
			<Style x:Key="TabItemFocusVisual">
				<Setter Property="Control.Template">
					<Setter.Value>
						<ControlTemplate>
							<Rectangle Stroke="Black" StrokeDashArray="1 2" StrokeThickness="1" Margin="3,3,3,1" SnapsToDevicePixels="true"/>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>
			<SolidColorBrush x:Key="TabControlNormalBorderBrush" Color="#8C8E94"/>
			<LinearGradientBrush x:Key="TabItemHotBackground" EndPoint="0,1" StartPoint="0,0">
				<GradientStop Color="#EAF6FD" Offset="0.15"/>
				<GradientStop Color="#D9F0FC" Offset=".5"/>
				<GradientStop Color="#BEE6FD" Offset=".5"/>
				<GradientStop Color="#A7D9F5" Offset="1"/>
			</LinearGradientBrush>
			<SolidColorBrush x:Key="TabItemSelectedBackground" Color="#F9F9F9"/>
			<SolidColorBrush x:Key="TabItemHotBorderBrush" Color="#3C7FB1"/>
			<SolidColorBrush x:Key="TabItemDisabledBackground" Color="#F4F4F4"/>
			<SolidColorBrush x:Key="TabItemDisabledBorderBrush" Color="#FFC9C7BA"/>
			<Style x:Key="TabItemStyle2" d:IsControlPart="True" TargetType="{x:Type TabItem}">
				<Setter Property="Template">
					<Setter.Value>
						<ControlTemplate TargetType="{x:Type TabItem}">
							<Grid>
								<Border Margin="0,0,-4,0" x:Name="Border" Background="{DynamicResource LightBrush}" BorderBrush="{DynamicResource SolidBorderBrush}" BorderThickness="1,1,1,1" CornerRadius="2,12,0,0">
									<ContentPresenter HorizontalAlignment="Center" Margin="12,2,12,2" x:Name="ContentSite" VerticalAlignment="Center" RecognizesAccessKey="True" ContentSource="Header"/>
								</Border>
							</Grid>
							<ControlTemplate.Triggers>
								<Trigger Property="IsSelected" Value="True">
									<Setter Property="Panel.ZIndex" Value="100"/>
									<Setter Property="Background" Value="{DynamicResource WindowBackgroundBrush}" TargetName="Border"/>
									<Setter Property="BorderThickness" Value="1,1,1,0" TargetName="Border"/>
								</Trigger>
								<Trigger Property="IsEnabled" Value="False">
									<Setter Property="Background" Value="{DynamicResource DisabledBackgroundBrush}" TargetName="Border"/>
									<Setter Property="BorderBrush" Value="{DynamicResource DisabledBorderBrush}" TargetName="Border"/>
									<Setter Property="Foreground" Value="{DynamicResource DisabledForegroundBrush}"/>
								</Trigger>
							</ControlTemplate.Triggers>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>
			<Style x:Key="TabControlStyle1" TargetType="{x:Type TabControl}">
				<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
				<Setter Property="Padding" Value="4,4,4,4"/>
				<Setter Property="BorderThickness" Value="1"/>
				<Setter Property="BorderBrush" Value="{StaticResource TabControlNormalBorderBrush}"/>
				<Setter Property="Background" Value="#F9F9F9"/>
				<Setter Property="HorizontalContentAlignment" Value="Center"/>
				<Setter Property="VerticalContentAlignment" Value="Center"/>
				<Setter Property="Template">
					<Setter.Value>
						<ControlTemplate TargetType="{x:Type TabControl}">
							<Grid ClipToBounds="true" SnapsToDevicePixels="true" KeyboardNavigation.TabNavigation="Local">
								<Grid.ColumnDefinitions>
									<ColumnDefinition x:Name="ColumnDefinition0"/>
									<ColumnDefinition x:Name="ColumnDefinition1" Width="0"/>
								</Grid.ColumnDefinitions>
								<Grid.RowDefinitions>
									<RowDefinition x:Name="RowDefinition0" Height="Auto"/>
									<RowDefinition x:Name="RowDefinition1" Height="*"/>
								</Grid.RowDefinitions>
								<TabPanel x:Name="HeaderPanel" Margin="15,2,2,0" IsItemsHost="true" Panel.ZIndex="1" Grid.Column="0" Grid.Row="0" KeyboardNavigation.TabIndex="1"/>
								<Border x:Name="ContentPanel" Background="{TemplateBinding Background}" Grid.Column="0" Grid.Row="1" KeyboardNavigation.DirectionalNavigation="Contained" KeyboardNavigation.TabIndex="2" KeyboardNavigation.TabNavigation="Local" CornerRadius="15" BorderThickness="1" BorderBrush="{TemplateBinding BorderBrush}">
									<Border Margin="10" BorderThickness="1" Background="{DynamicResource HatchedBrush}" CornerRadius="15" BorderBrush="#FFB2DAE8">
										<ContentPresenter x:Name="PART_SelectedContentHost" Margin="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" ContentSource="SelectedContent"/>
									</Border>
								</Border>
							</Grid>
							<ControlTemplate.Triggers>
								<Trigger Property="TabStripPlacement" Value="Bottom">
									<Setter Property="Grid.Row" TargetName="HeaderPanel" Value="1"/>
									<Setter Property="Grid.Row" TargetName="ContentPanel" Value="0"/>
									<Setter Property="Height" TargetName="RowDefinition0" Value="*"/>
									<Setter Property="Height" TargetName="RowDefinition1" Value="Auto"/>
									<Setter Property="Margin" TargetName="HeaderPanel" Value="2,0,2,2"/>
								</Trigger>
								<Trigger Property="TabStripPlacement" Value="Left">
									<Setter Property="Grid.Row" TargetName="HeaderPanel" Value="0"/>
									<Setter Property="Grid.Row" TargetName="ContentPanel" Value="0"/>
									<Setter Property="Grid.Column" TargetName="HeaderPanel" Value="0"/>
									<Setter Property="Grid.Column" TargetName="ContentPanel" Value="1"/>
									<Setter Property="Width" TargetName="ColumnDefinition0" Value="Auto"/>
									<Setter Property="Width" TargetName="ColumnDefinition1" Value="*"/>
									<Setter Property="Height" TargetName="RowDefinition0" Value="*"/>
									<Setter Property="Height" TargetName="RowDefinition1" Value="0"/>
									<Setter Property="Margin" TargetName="HeaderPanel" Value="2,2,0,2"/>
								</Trigger>
								<Trigger Property="TabStripPlacement" Value="Right">
									<Setter Property="Grid.Row" TargetName="HeaderPanel" Value="0"/>
									<Setter Property="Grid.Row" TargetName="ContentPanel" Value="0"/>
									<Setter Property="Grid.Column" TargetName="HeaderPanel" Value="1"/>
									<Setter Property="Grid.Column" TargetName="ContentPanel" Value="0"/>
									<Setter Property="Width" TargetName="ColumnDefinition0" Value="*"/>
									<Setter Property="Width" TargetName="ColumnDefinition1" Value="Auto"/>
									<Setter Property="Height" TargetName="RowDefinition0" Value="*"/>
									<Setter Property="Height" TargetName="RowDefinition1" Value="0"/>
									<Setter Property="Margin" TargetName="HeaderPanel" Value="0,2,2,2"/>
								</Trigger>
								<Trigger Property="IsEnabled" Value="false">
									<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
								</Trigger>
							</ControlTemplate.Triggers>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>
			<Style x:Key="TabItemStyle1" TargetType="{x:Type TabItem}">
				<Setter Property="FocusVisualStyle" Value="{StaticResource TabItemFocusVisual}"/>
				<Setter Property="Foreground" Value="Black"/>
				<Setter Property="Padding" Value="6,1,6,1"/>
				<Setter Property="BorderBrush" Value="{StaticResource TabControlNormalBorderBrush}"/>
				<Setter Property="Background" Value="{StaticResource ButtonNormalBackground}"/>
				<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
				<Setter Property="VerticalContentAlignment" Value="Stretch"/>
				<Setter Property="Template">
					<Setter.Value>
						<ControlTemplate TargetType="{x:Type TabItem}">
							<Grid SnapsToDevicePixels="true">
								<Border x:Name="Bd" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1,1,1,0" Padding="{TemplateBinding Padding}" CornerRadius="10,10,0,0">
									<ContentPresenter x:Name="Content" HorizontalAlignment="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" VerticalAlignment="{Binding VerticalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" ContentSource="Header" RecognizesAccessKey="True"/>
								</Border>
							</Grid>
							<ControlTemplate.Triggers>
								<Trigger Property="IsMouseOver" Value="true">
									<Setter Property="Background" TargetName="Bd" Value="{StaticResource TabItemHotBackground}"/>
								</Trigger>
								<Trigger Property="IsSelected" Value="true">
									<Setter Property="Panel.ZIndex" Value="1"/>
									<Setter Property="Background" TargetName="Bd" Value="{StaticResource TabItemSelectedBackground}"/>
								</Trigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="false"/>
										<Condition Property="IsMouseOver" Value="true"/>
									</MultiTrigger.Conditions>
									<Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource TabItemHotBorderBrush}"/>
								</MultiTrigger>
								<Trigger Property="TabStripPlacement" Value="Bottom">
									<Setter Property="BorderThickness" TargetName="Bd" Value="1,0,1,1"/>
								</Trigger>
								<Trigger Property="TabStripPlacement" Value="Left">
									<Setter Property="BorderThickness" TargetName="Bd" Value="1,1,0,1"/>
								</Trigger>
								<Trigger Property="TabStripPlacement" Value="Right">
									<Setter Property="BorderThickness" TargetName="Bd" Value="0,1,1,1"/>
								</Trigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Top"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-2,-2,-2,-1"/>
									<Setter Property="Margin" TargetName="Content" Value="0,0,0,1"/>
								</MultiTrigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Bottom"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-2,-1,-2,-2"/>
									<Setter Property="Margin" TargetName="Content" Value="0,1,0,0"/>
								</MultiTrigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Left"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-2,-2,-1,-2"/>
									<Setter Property="Margin" TargetName="Content" Value="0,0,1,0"/>
								</MultiTrigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Right"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-1,-2,-2,-2"/>
									<Setter Property="Margin" TargetName="Content" Value="1,0,0,0"/>
								</MultiTrigger>
								<Trigger Property="IsEnabled" Value="false">
									<Setter Property="Background" TargetName="Bd" Value="{StaticResource TabItemDisabledBackground}"/>
									<Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource TabItemDisabledBorderBrush}"/>
									<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
								</Trigger>
							</ControlTemplate.Triggers>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>
			<Style x:Key="TabItemStyle3" TargetType="{x:Type TabItem}">
				<Setter Property="FocusVisualStyle" Value="{StaticResource TabItemFocusVisual}"/>
				<Setter Property="Foreground" Value="Black"/>
				<Setter Property="Padding" Value="6,1,6,1"/>
				<Setter Property="BorderBrush" Value="{StaticResource TabControlNormalBorderBrush}"/>
				<Setter Property="Background" Value="{StaticResource ButtonNormalBackground}"/>
				<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
				<Setter Property="VerticalContentAlignment" Value="Stretch"/>
				<Setter Property="Template">
					<Setter.Value>
						<ControlTemplate TargetType="{x:Type TabItem}">
							<Grid SnapsToDevicePixels="true">
								<Border x:Name="Bd" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1,1,1,0" Padding="{TemplateBinding Padding}" CornerRadius="10,10,0,0">
									<ContentPresenter x:Name="Content" HorizontalAlignment="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" VerticalAlignment="{Binding VerticalContentAlignment, RelativeSource={RelativeSource AncestorType={x:Type ItemsControl}}}" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" ContentSource="Header" RecognizesAccessKey="True"/>
								</Border>
							</Grid>
							<ControlTemplate.Triggers>
								<Trigger Property="IsMouseOver" Value="true">
									<Setter Property="Background" TargetName="Bd" Value="{StaticResource TabItemHotBackground}"/>
								</Trigger>
								<Trigger Property="IsSelected" Value="true">
									<Setter Property="Panel.ZIndex" Value="1"/>
									<Setter Property="Background" TargetName="Bd" Value="{StaticResource TabItemSelectedBackground}"/>
								</Trigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="false"/>
										<Condition Property="IsMouseOver" Value="true"/>
									</MultiTrigger.Conditions>
									<Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource TabItemHotBorderBrush}"/>
								</MultiTrigger>
								<Trigger Property="TabStripPlacement" Value="Bottom">
									<Setter Property="BorderThickness" TargetName="Bd" Value="1,0,1,1"/>
								</Trigger>
								<Trigger Property="TabStripPlacement" Value="Left">
									<Setter Property="BorderThickness" TargetName="Bd" Value="1,1,0,1"/>
								</Trigger>
								<Trigger Property="TabStripPlacement" Value="Right">
									<Setter Property="BorderThickness" TargetName="Bd" Value="0,1,1,1"/>
								</Trigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Top"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-2,-2,-2,-1"/>
									<Setter Property="Margin" TargetName="Content" Value="0,0,0,1"/>
								</MultiTrigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Bottom"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-2,-1,-2,-2"/>
									<Setter Property="Margin" TargetName="Content" Value="0,1,0,0"/>
								</MultiTrigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Left"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-2,-2,-1,-2"/>
									<Setter Property="Margin" TargetName="Content" Value="0,0,1,0"/>
								</MultiTrigger>
								<MultiTrigger>
									<MultiTrigger.Conditions>
										<Condition Property="IsSelected" Value="true"/>
										<Condition Property="TabStripPlacement" Value="Right"/>
									</MultiTrigger.Conditions>
									<Setter Property="Margin" Value="-1,-2,-2,-2"/>
									<Setter Property="Margin" TargetName="Content" Value="1,0,0,0"/>
								</MultiTrigger>
								<Trigger Property="IsEnabled" Value="false">
									<Setter Property="Background" TargetName="Bd" Value="{StaticResource TabItemDisabledBackground}"/>
									<Setter Property="BorderBrush" TargetName="Bd" Value="{StaticResource TabItemDisabledBorderBrush}"/>
									<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/>
								</Trigger>
							</ControlTemplate.Triggers>
						</ControlTemplate>
					</Setter.Value>
				</Setter>
			</Style>
		</ResourceDictionary>
	</Window.Resources>
	<Window.Triggers>
		<EventTrigger RoutedEvent="FrameworkElement.Loaded">
			<BeginStoryboard Storyboard="{StaticResource Storyboard1}"/>
		</EventTrigger>
	</Window.Triggers>
	<Window.Background>
		<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
			<GradientStop Color="White"/>
			<GradientStop Color="White" Offset="0.996"/>
			<GradientStop Color="#FF9DA6DE" Offset="0.504"/>
		</LinearGradientBrush>
	</Window.Background>
	<DockPanel x:Name="LayoutRoot">
		<ToolBarPanel HorizontalAlignment="Left" Margin="0,0,0,15" VerticalAlignment="Bottom" DockPanel.Dock="Top" Orientation="Horizontal"/>
		<TabControl Margin="5,0,10,10" RenderTransformOrigin="0.5,0.5" Style="{DynamicResource TabControlStyle1}" Background="White" Foreground="{x:Null}" BorderBrush="{DynamicResource DefaultedBorderBrush}" ItemContainerStyle="{DynamicResource TabItemStyle3}" >
			<TabControl.Resources>
				<ResourceDictionary>
					<ResourceDictionary.MergedDictionaries>
						<ResourceDictionary Source="Simple Styles.xaml"/>
					</ResourceDictionary.MergedDictionaries>
				</ResourceDictionary>
			</TabControl.Resources>
			<TabControl.RenderTransform>
				<TransformGroup>
					<ScaleTransform ScaleX="1" ScaleY="1"/>
					<SkewTransform AngleX="0" AngleY="0"/>
					<RotateTransform Angle="0"/>
					<TranslateTransform/>
				</TransformGroup>
			</TabControl.RenderTransform>
			<TabControl.Effect>
				<DropShadowEffect BlurRadius="24" Direction="291"/>
			</TabControl.Effect>
			<TabItem Margin="0" Header="TabItem">
				<Grid/>
			</TabItem>
		</TabControl>
	</DockPanel>
</Window>